package com.authine.cloudpivot.app.openapi.repository.databaseobject;

import io.swagger.annotations.ApiModel;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.persistence.*;
import java.util.Date;

/**
 * @author lifuchun
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@ApiModel("路由配置")
@Table(name = "openapi_route_config")
public class RouteConfigDO {
    /**
     * 自增主键
     */
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Integer id;

    /**
     * 路由的id
     */
    @Column(name = "route_id")
    private String routeId;

    /**
     * 排序号
     */
    @Column(name = "route_order")
    private Integer routeOrder;

    /**
     * 转发的uri
     */
    @Column(name = "route_uri")
    private String routeUri;

    /**
     * 过滤器配置
     */
    @Column(name = "route_filters")
    private String routeFilters;

    /**
     * 断言配置
     */
    @Column(name = "route_predicates")
    private String routePredicates;

    /**
     * 断言配置
     */
    @Column(name = "route_metadata")
    private String routeMetadata;

    /**
     * 备注说明，路由干啥用
     */
    private String memo;

    /**
     * 创建时间
     */
    private Date created;

    /**
     * 更新时间
     */
    private Date updated;

    /**
     * 删除标记，1删除 0 正常
     */
    private Byte deleted;


}